package maskedpixel.ogmo.utils 
{
	/**
	 * ...
	 * @author Erin M Gunn
	 */
	public class OgmoNode 
	{
		/**
		 * Determines whether Ogmo Editor should draw this node or not.
		 */
		public var drawObject:Boolean;
		
		/**
		 * The type of line drawing used by Ogmo for this node.
		 */
		public var lineMode:uint;
		
		/**
		 * The maximum number of nodes.
		 */
		public var limit:uint;
		
		/**
		 * Constructor.
		 * @param	drawObject	Whether or not to draw this Node in Ogmo Editor.
		 * @param	lineMode	They type of line drawing used by Ogmo on this object.
		 * @param	limit		The maximum number of nodes.
		 */
		public function OgmoNode(drawObject:Boolean, lineMode:uint, limit:uint) 
		{
			this.drawObject = drawObject;
			this.lineMode = lineMode;
			this.limit = limit;
		}
		
		/**
		 * Generate the XML representing this Node in the Ogmo project file.
		 * @return
		 */
		public function generateXML():XML 
		{
			var xml:XML = new XML();
			xml = <nodes/>;
			xml.@drawObject = drawObject;
			xml.@lineMode = lineMode;
			xml.@limit = limit;
			return xml;
		}
		
	}

}